package com.husd.framework.unicode;

public class Number {

    public void testUnicode() {

        System.out.println("\\u4E25");

        int num = Character.digit('\uFF41',16);
        System.out.println(num);

        int num2 = 123_345;
        System.out.println("num2 is :" + num2);

        double num3 = .1234;
        System.out.println("num3 is :" + num3);

        char c = 'a';
        char c1 = '\uFF41';
        char c2 = '\\';
        char c3 = '1'; // 0-9
        char c4 = '\012'; // 这种是八进制转char 这种声明晦涩难懂 少见
        char c5 = '\t';
        char c6 = '\7';

        System.out.println("c6 is:" + c6);

        //java里的各种进制表示方法
        int n1 = 0b101; // 二进制的5
        double n2 = 0e1011; // 0.0
        int n3 = 011; // 八进制的 9
        int n4 = 11; // 十进制的 11
        int n5 = 0x11; // 十六进制的 17

        int a // 1234
                = 4;
        int a1 = 100;
        int a2 = 100_0;
        int a3 = 100__0;
        int a4 = 1_00_0;

        System.out.println("-0 and +0 result:" + (-0 == +0));
    }
}
